chore: typos, formatting and refactor#145
chore: typos, formatting and refactor#145selmanozleyen wants to merge 35 commits intoscverse:mainfrom
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #145 +/- ##
==========================================
- Coverage 93.71% 91.51% -2.21%
==========================================
Files 11 11
Lines 812 813 +1
==========================================
- Hits 761 744 -17
- Misses 51 69 +18
🚀 New features to boost your workflow:
|
|
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
for more information, see https://pre-commit.ci
ilan-gold
left a comment
There was a problem hiding this comment.
Just more places for consistency. Why go with anndata over adata? I'm really asking for feedback, I think adata is used for the actual object generally i.e., adata = read_h5ad but not anndata = read_h5ad
For me it both was same so I wanted to minimize the breaking impact and guessed Loader was used more. Also thought, as you said, "anndata is a class name vs adata is an instance name". Like we take any anndata not a specific adata. I would go with whatever is more adapted in the ecosystem but I don't have any insights on that. |
Co-authored-by: Ilan Gold <ilanbassgold@gmail.com>
|
LGTM! Another minor fix: Could you provide a the number of iterations here. This gets broken by using Line 181 in d47240f this has been bugging me for ages Moreover, the progress bar descriptions should get updated: Would be cool if you could add this to this PR. Otherwise, I can create a separate PR myself @selmanozleyen |
"anndata" is the library name. "AnnData" is the class name. In any case, some spatial data folks concur with |
Hi, there were some things bugging me and I wanted to clean some stuff and point out some inconsistencies but I also didn't want this to be in other unrelated PR's so here is a contained PR consisting of some of the things that bugged me. I will revert some commits based on whatever you guys would want to undo.
Here is an ai-based report of the changes by commits
Changes
Breaking: Rename
add_adatastoadd_anndatasfor consistent naming (selmanozleyen@2558b40, selmanozleyen@304dcbb and a60774c)DatasetCollection.add_adatas->DatasetCollection.add_anndatasFix "Wether" typo in
io.py(5232e12)DatasetCollection.is_emptydocstring: "Wether" -> "Whether"Define
_collection_addedas a class attribute inloader.py(5d14e5c)_collection_added: bool = Falseis now declared on theLoaderdataclass directly, instead of being accessed viagetattr(self, "_collection_added", False).Fix "who" typo in
loader.py(d841e13)Loader.use_collection: "The collection who on-disk datasets" -> "The collection whose on-disk datasets"Ruff format
test_dataset.py(36af588)test_dataset.py(whitespace-only change by ruff)other mypy fixes but I don't mind them that much
4958749-- addtorch.*andh5py.*to mypyignore_missing_imports830f2d4-- fixMapping.copy()call inwrite_shardedcallback (dict(dataset_kwargs))6d6067a-- wrap categories inpd.IndexforCategorical.from_codes12830d5-- replace match/case with if/elif for better mypy narrowing in_create_chunks_for_shuffling